package com.bioroadlab.pojo;

import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * TestStatus entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "test_status", catalog = "bioroadlab")
public class TestStatus implements java.io.Serializable {

	// Fields

	private static final long serialVersionUID = 1L;

	private Integer sn;
	private String name;
	private Set<SampleInfo> sampleInfos = new HashSet<SampleInfo>(0);

	@Id
	@Column(name = "sn", unique = true, nullable = false)
	public Integer getSn() {
		return this.sn;
	}

	public void setSn(Integer sn) {
		this.sn = sn;
	}

	@Column(name = "name", length = 20)
	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.EAGER, mappedBy = "testStatus")
	public Set<SampleInfo> getSampleInfos() {
		return this.sampleInfos;
	}

	public void setSampleInfos(Set<SampleInfo> sampleInfos) {
		this.sampleInfos = sampleInfos;
	}

}